package com.zjyd.douyangsearch.mode;

import lombok.Data;
import org.dromara.easyes.annotation.IndexField;
import org.dromara.easyes.annotation.IndexId;
import org.dromara.easyes.annotation.IndexName;
import org.dromara.easyes.annotation.rely.Analyzer;
import org.dromara.easyes.annotation.rely.FieldType;
import org.dromara.easyes.annotation.rely.IdType;

@Data
@IndexName(value="sjy_news_index")
public class NewsEs {
    //IdType.CUSTOMIZE 才是用户自定义
    @IndexId(type= IdType.CUSTOMIZE)
    private String id;

    /**
     *
     */
    @IndexField(fieldType = FieldType.TEXT, analyzer = Analyzer.IK_SMART, searchAnalyzer = Analyzer.IK_MAX_WORD)
    private String title;

    @IndexField(fieldType = FieldType.TEXT, analyzer = Analyzer.IK_SMART, searchAnalyzer = Analyzer.IK_MAX_WORD)
    private String content;

    @IndexField
    private String author;


    @IndexField
    private String createTime;
    @IndexField
    private String deleted;
}
